<style type="text/css">
	.btn{
		background: #4966ff none repeat scroll 0 0;
    border: 0 none;
    color: #fff;
    cursor: pointer;
    display: inline-block;
    font-size: 16px;
    height: 30px;
    line-height: 24px;
    margin-right: 15px;
    width: 80px;
	}
</style>
<div class="boxer">
	<div class="box">
		<div class="catname">
			<h2 class="jiaose-list-ico">敏感词导入</h2>
		</div>
		<div class="default-table-box">
		<form method="POST" action="/badword/add" enctype="multipart/form-data">
				选择上传excel：
				<input type="file" class="t" name="badword" accept=".xlsx,.xls"  />
				<input type="submit" class="btn" value="导入" />
				<input type="button" class="btn" value="取消" />
				<br class="clr" />
			</form>
			</div>
	</div>
	<form method="POST" action="/badword/duplicate" class="ck">
				<input type="hidden" name="names" value="{{.names}}"  />
	</form>
</div>
<script type="text/javascript">
jQuery(function($){	
	nku.droplist.config({'theme':'win7'}).play('black-search-qy');
	var err={{.err}}
	if (err=="err"){
		layer.msg("请选择导入文件")
	}else{
		var cf={{.dupCount}}
		if(cf=="0"){
			layer.confirm('本次共导入敏感词<em>{{.total}}</em>个，其中重复<em>{{.dupCount}}</em>个，实际导入<em>{{.realCount}}</em>个,是否查看重复列表?', {
	    	  title: '导入敏感词',
			  btn: ['取消']
			},
			function(){
					location.href='/badword/index';
			});
		}else{
			layer.confirm('本次共导入敏感词<em>{{.total}}</em>个，其中重复<em>{{.dupCount}}</em>个，实际导入<em>{{.realCount}}</em>个,是否查看重复列表?', {
	    	  title: '导入敏感词',
			  btn: ['查看重复敏感词','取消']
			},
			function(index){
				$(".ck").submit()
				},
			function(){
					location.href='/badword/index';
			});
		}
				
	}
});
</script>